<?php

/**
 * Application level View Helper
 *
 * This file is application-wide helper file. You can put all
 * application-wide helper-related methods here.
 *
 * PHP versions 5
 * CAKEPHP versions 2.x
 * 
 * Green CMS - Content Management System and Framework Powerfull by Cakephp
 * Copyright 2012, GREEN GLOBAL CO., LTD (toancauxanh.vn)
 * 
 * CakePHP(tm) :  Rapid Development Framework (http://www.cakephp.org)
 * Copyright 2005-2011, Cake Software Foundation, Inc. (http://www.cakefoundation.org)
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @author        Technology Lab No.I <tech1@toancauxanh.vn>
 * @link          
 * @package       Green.Helper
 * @since         Green v 1.0
 * @license       MIT License (http://www.opensource.org/licenses/mit-license.php)
 */
App::uses('Helper', 'View');
App::uses('CakeEventListener', 'Event');

/**
 * Application helper
 *
 * Add your application-wide methods in the class below, your helpers
 * will inherit them.
 *
 * @package       Green.Helper
 */
class AppHelper extends Helper implements CakeEventListener {

    /**
     * Returns the CakeEventManager manager instance that is handling any callbacks.
     * You can use this instance to register any new listeners or callbacks to the
     * controller events, or create your own events and trigger them at will.
     *
     * @return CakeEventManager
     */
    public function getEventManager() {
        return $this->_View->Helpers->getEventManager();
    }

    /**
     * Returns a list of events this object is implementing, when the class is registered
     * in an event manager, each individual method will be associated to the respective event.
     *
     * @return array associative array or event key names pointing to the function
     * that should be called in the object when the respective event is fired
     */
    public function implementedEvents() {
        return array();
    }

}
